<template>
  <div class="pagination">
    <el-pagination
      background
      layout="prev, pager, next"
      :total="vTotal"
      :page-size="vPageSize"
      @current-change="getCurrentPage"
      class="el-pagination">
    </el-pagination>
  </div>
</template>

<script>
export default {
  props: ['total', 'ips', 'sendCurrentPage'],
  data() {
    return {
      vTotal: Number(this.total),
      vPageSize: Number(this.ips)
    }
  },
  methods: {
    getCurrentPage(val) {
      this.$emit('currentPage',val)
    }
  },
  watch: {
    total() {
      this.vTotal = Number(this.total)
    },
    sendCurrentPage() {
     
    }
  }
}
</script>

<style scoped>
.pagination {
  margin-top: 20px;
  text-align: center;
}
.el-pagination {
  padding-right: 0;
  /* background-color: $mainColor; */
}
</style>


